Skip to content

[ENG-1851] Add Roam single-node publish action#1132

Merged
sid597 merged 9 commits into
eng-1890-add-publish-tab-to-roam-query-results-share-dialogfrom
eng-1851-add-roam-single-node-share-action
Jun 26, 2026
Merged

[ENG-1851] Add Roam single-node publish action#1132
sid597 merged 9 commits into
eng-1890-add-publish-tab-to-roam-query-results-share-dialogfrom
eng-1851-add-roam-single-node-share-action

Conversation

@sid597

@sid597 sid597 commented Jun 19, 2026

Copy link
Copy Markdown
Collaborator

https://www.loom.com/share/7c761a98168a41f1a58dd046b593bd18

What changed

ENG-1851 is now stacked on ENG-1890 and wires Roam single-node publishing into the existing Share Data dialog.

  • Adds DG: Share current node for the current user-backed discourse node.
  • Adds a page-title Publish button on discourse node pages.
  • Opens Share Data directly on the Publish tab with exactly one selected node.
  • Reuses ENG-1890's Publish tab/group-grant path instead of duplicating publish logic.
  • Aligns title additions so Publish and the discourse context overlay render side by side, while full-width panels such as Possible Duplicates remain below.

Test result

Built and copied the Roam extension bundle to /mnt/data/projects/dg-test-eng-1851 with Supabase env loaded.

Runtime test:

  • Published [[NOD]] - test page 3 via the page-title Publish button.
  • Selected/source-local node UID: WIsbIYJIA.
  • Selected group: 1a752508-6281-4270-a5ef-3a23cbfc047c.
  • Source space: 105833.

Supabase verification:

  • ResourceAccess exists for selected node UID WIsbIYJIA and group 1a752508-6281-4270-a5ef-3a23cbfc047c.
  • SpaceAccess.permissions = partial exists for the same group and space.
  • Schema/type dependency grant exists for source-local id lwEYjIASO (NODE 1).

This proves the actual publish path rather than duplicate-node/vector-search behavior, because duplicate detection may use synced concepts/content/embeddings but does not create ResourceAccess or SpaceAccess group grants.

Scope note

This validates ENG-1851's action/wiring and group-scoped publish grant behavior. Full cross-user discovery/consumption remains ENG-1854 validation territory.

Add a 'DG: Share current node' command-palette action, gated on
isSyncEnabled(). It deterministically captures the current page's
discourse node (page uid = source-local id), validates it via
findDiscourseNode, and opens the existing Share Data dialog with
exactly one node.

The Publish-tab handoff (initialPanel: "publish") is deferred to
ENG-1890, which owns Export.tsx's initialPanel union and the tab;
finishing it is a one-line change to the exportRender call here.

Mirrors Obsidian's publish-discourse-node command and Roam's
exportCurrentPage.
@linear-code

linear-code Bot commented Jun 19, 2026

Copy link
Copy Markdown

ENG-1851

@supabase

supabase Bot commented Jun 19, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project zytfjzqyijgagqxrzbmz because there are no changes detected in packages/database/supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@vercel

vercel Bot commented Jun 19, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
discourse-graph Skipped Skipped Jun 23, 2026 6:33pm

Request Review

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

Open in Devin Review

Comment thread apps/roam/src/utils/registerCommandPaletteCommands.ts Outdated
@graphite-app

graphite-app Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

PR size/scope check

This PR is over our review-size guideline.

  • Recommended: ~200 lines changed
  • Acceptable limit: up to 400 lines when well-scoped/self-contained
  • Preferred file count: fewer than 5 files

Please split this into smaller PRs unless there is a clear reason the changes need to land together.

If keeping it as one PR, please add a brief justification covering:

  • What single problem this PR solves
  • Why the files/changes are coupled

@sid597 sid597 changed the base branch from main to eng-1890-add-publish-tab-to-roam-query-results-share-dialog June 22, 2026 13:44
@sid597 sid597 changed the title [ENG-1851] Add Roam single-node share command (capture-half) [ENG-1851] Add Roam single-node publish action Jun 22, 2026
@sid597 sid597 requested review from maparent and mdroidian and removed request for maparent and mdroidian June 23, 2026 18:13
…-query-results-share-dialog' into eng-1851-add-roam-single-node-share-action
@sid597 sid597 requested review from maparent and mdroidian June 23, 2026 19:18

maparent commented Jun 25, 2026

Copy link
Copy Markdown
Collaborator

A bit confused: the description and loom do not seem to fit the PR anymore. I do not see a 'DG: Share current node' or Publish button. Were those dropped or am I missing some settings? I do see the group logic in the export node dialog, so I know I'm on the right branch. Nope I was on the 1890 branch sorry.

Copy link
Copy Markdown
Collaborator

I got a bit confused by the branch interdependent structure. Not going to ask for a reorg, but thinking forward: I think it would be good practice to separate common code, such as the (excellent) refactoring where group functions are pushed to database in a separate PR, which both 1851 and 1890 could then build on for ux-specific adjustments. (OTH it's easier to test when logic and ux are together, but in this case we're mostly doing refactorings, and some code ported from obsidian.)

Copy link
Copy Markdown
Collaborator

Visual issue:

FLO Create DG node Roam interface

I think the duplicates should be on a separate line.

Copy link
Copy Markdown
Collaborator

And I see now 1851 is stacked on 1890. You made that explicit. Would be more legible with rebase than merge, but that's a nit.

@maparent maparent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Existing code logic lgtm.
Nit: As commented in linear, the "Possible duplicates" button probably deserves a new line.
Scoping: The obsidian button tells you how many groups was the node published to. Is that something we want in Roam? Maybe scope creep, but I suggest we create a separate triage task for that functionality.

@sid597

sid597 commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator Author

@maparent created a new task to remove this feature because we don't need it.

ENG-1953: Remove Duplicate node alert on DG pages

@sid597 sid597 requested a review from maparent June 26, 2026 12:30

@maparent maparent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Created FEE-845 for the publish button status, moving it out of scope.

@sid597 sid597 merged commit c80b7bd into eng-1890-add-publish-tab-to-roam-query-results-share-dialog Jun 26, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants